package domain;

public class Time {

	private Long id;
	private java.sql.Time timeFrom;
	private java.sql.Time timeTo;
	private String note;
	private TimeType timeType;
	private Workday workday;

	public Time() {
		super();
	}

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public java.sql.Time getTimeFrom() {
		return timeFrom;
	}

	public void setTimeFrom(java.sql.Time timeFrom) {
		this.timeFrom = timeFrom;
	}

	public java.sql.Time getTimeTo() {
		return timeTo;
	}

	public void setTimeTo(java.sql.Time timeTo) {
		this.timeTo = timeTo;
	}

	public String getNote() {
		return note;
	}

	public void setNote(String note) {
		this.note = note;
	}

	public TimeType getTimeType() {
		return timeType;
	}

	public void setTimeType(TimeType timeType) {
		this.timeType = timeType;
	}

	public Workday getWorkday() {
		return workday;
	}

	public void setWorkday(Workday workday) {
		this.workday = workday;
	}

	@Override
	public String toString() {
		return "Od: "
				+ getTimeFrom().toString().substring(0,
						getTimeFrom().toString().length() - 3)
				+ " Do:"
				+ getTimeTo().toString().substring(0,
						getTimeTo().toString().length() - 3) + " timeType: " + getTimeType().toString();
	}
}
